<!DOCTYPE html>
<link rel="author" title="Morten Stenshorne" href="mailto:mstensho@chromium.org">
<style>
  @page {
    size: 20em 7em;
    margin: 0;
  }
  .pagebox {
    break-before: page;
    display: flex;
    width: 20em;
    height: 7em;
  }
  .pagebox > div {
    width: 12em;
    height: 3em;
    margin: auto;
    background: yellow;
  }
  body {
    margin: 0;
  }
</style>
<div class="pagebox">
  <div>center / middle</div>
</div>
<div class="pagebox">
  <div style="margin-top:0;">center / top</div>
</div>
<div class="pagebox">
  <div style="margin-bottom:0;">center / bottom</div>
</div>
<div class="pagebox">
  <div style="margin-top:0; margin-left:0;">top / left</div>
</div>
<div class="pagebox">
  <div style="margin-top:0; margin-right:0;">top / right</div>
</div>
<div class="pagebox">
  <div style="margin-bottom:0; margin-right:0;">bottom / right</div>
</div>
